package com.tc.juc.pack05;

import lombok.extern.slf4j.Slf4j;

/**
 * @Auther: tianchao
 * @Date: 2021/10/4 22:40
 * @Description:
 */
@Slf4j
public class Test32 {
    static volatile boolean run = true;
    public static void main(String[] args) {
        Thread t = new Thread(()->{
            while (run){
//                synchronized (Test32.class){
//
//                }
            }
        });
        t.start();
        try {
            Thread.sleep(1000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        log.info("停止");
        run = false;
    }
}
